package cn.org.zych;

public abstract class AbstractCallBack {

    abstract byte[] findPdf(String id);

    protected abstract String upload(byte[] pdfBty);

    protected abstract void invoke(String filePath);

    public void callback(String id){
        byte[] pdfBty = findPdf(id);
        if(pdfBty!=null && pdfBty.length>0){
            String filePath = upload(pdfBty);
            invoke(filePath);
        }
    }
}
